package com.molichuxing.services.business.service;

import com.molichuxing.framework.dto.Paged;
import com.molichuxing.services.business.dto.request.create.MessageCenterReqDto;
import com.molichuxing.services.business.dto.response.MessageResDto;
import com.molichuxing.services.infrastructure.dto.response.VersionMobileDto;

import java.util.Map;

/**
 * <p>
 * 消息服务类
 * </p>
 *
 * @author
 * @since 2019-07-29
 */
public interface MessageBizService {

	/**
	 * 添加消息
	 * @param messageReqDto
	 * @return
	 */
	public boolean insertMessage(MessageCenterReqDto messageReqDto);

	/**
	 * 根据用户id查询消息
	 * @param userId
	 * @return
	 */
	public Paged<MessageResDto> selectMessagesByUserId(Integer userId, Integer pageNum, Integer pageSize);

	/**
	 * 查询未读消息数量
	 * @param userId
	 * @return
	 */
	public int selectMessagesListByUserId(Integer userId);

	/**
	 * 根据用户id查询该用户是否有未读消息
	 * @param userId
	 * @return
	 */
	public Map<String,Object> selectMessagesUnReadByUserId(Integer userId);
}
